home *** CD-ROM | disk | FTP | other *** search
- #define CURSES_LIBRARY 1
- #include <curses.h>
-
- #ifdef PDCDEBUG
- char *rcsid__getscrn = "$Header: C:\CURSES\private\RCS\_getscrn.c 2.1 1993/06/18 20:23:25 MH Rel MH $";
- #endif
-
-
-
-
- /*man-start*********************************************************************
-
- PDC_get_scrn_mode() - Return the current BIOS video mode
-
- PDCurses Description:
- This is a private PDCurses routine.
-
- Returns the current BIOS Video Mode Number.
-
- PDCurses Return Value:
- This function returns OK on success and ERR on error.
-
- PDCurses Errors:
- The FLEXOS version of this routine returns an ERR.
-
- Portability:
- PDCurses int PDC_get_scrn_mode( void );
-
- **man-end**********************************************************************/
-
- #ifdef OS2
- VIOMODEINFO PDC_get_scrn_mode(void)
- #else
- int PDC_get_scrn_mode(void)
- #endif
- {
- #ifdef OS2
- VIOMODEINFO vioModeInfo;
- #endif
-
- #ifdef PDCDEBUG
- if (trace_on) PDC_debug("PDC_get_scrn_mode() - called\n");
- #endif
-
- #ifdef FLEXOS
- return( ERR );
- #endif
-
- #ifdef DOS
- regs.h.ah = 0x0f;
- int86(0x10, ®s, ®s);
- return ((int) regs.h.al);
- #endif
-
- #ifdef OS2
- VioGetMode (&vioModeInfo, 0);
- return vioModeInfo;
- #endif
-
- #ifdef UNIX
- return(0); /* this is N/A */
- #endif
- }
-